﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true"
    CodeFile="Department.aspx.cs" Inherits="Department" Title="组织结构维护" Culture="auto"
    UICulture="auto" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder" runat="Server">
    <h1 id="pagetitle" class="pagetitle">
        组织部门信息管理
        <asp:UpdateProgress ID="UpdateProgress1" runat="server">
            <ProgressTemplate>
                <div class="anistyle" id="ani">
                    正在加载数据，请耐心等待...
                </div>
            </ProgressTemplate>
        </asp:UpdateProgress>
    </h1>
    <asp:UpdatePanel ID="UpdatePanel" runat="server">
        <ContentTemplate>
            <div class="condition">
                <div class="conditioninput">
                    <span>请选择要查看的部门：</span><asp:DropDownList ID="DDLdept" runat="server" AutoPostBack="True"
                        OnSelectedIndexChanged="DDLdept_SelectedIndexChanged" Width="212px">
                    </asp:DropDownList>
                </div>
                <div class="conditionbutton">
                </div>
            </div>
            <div runat="server" id="divResult" class="divResult">
                <asp:Label ID="OperationResult" CssClass="result" runat="server" Text=""></asp:Label>
            </div>
            <div class="InfoArea">
                <asp:Panel ID="EditPanel" runat="server" Width="100%">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="tablehaveborder">
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 120px; height: 24px;">
                                &nbsp;&nbsp;部门编号：</td>
                            <td style="width: 400px;">
                                <asp:Label ID="EditDept_ID" runat="server" Width="100%" class="id"></asp:Label></td>
                            <td style="width: 150px;">
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门名称：</td>
                            <td>
                                <asp:TextBox ID="EditDept_Name" runat="server" MaxLength="50" ValidationGroup="Edit"></asp:TextBox></td>
                            <td>
                                <asp:RequiredFieldValidator ID="EditDept_NameRequired" runat="server" ControlToValidate="EditDept_Name"
                                    Display="Dynamic" ErrorMessage="请输入部门名称！" ValidationGroup="Edit"></asp:RequiredFieldValidator>&nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;上级部门：</td>
                            <td>
                                <asp:DropDownList ID="EditDep_Dept_ID" runat="server" Width="152px" AutoPostBack="True"
                                    OnSelectedIndexChanged="EditDep_Dept_ID_SelectedIndexChanged">
                                </asp:DropDownList></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;联系电话：</td>
                            <td>
                                <asp:TextBox ID="EditDept_Tel" runat="server" MaxLength="50" ValidationGroup="Edit"></asp:TextBox></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门负责人：</td>
                            <td>
                                <asp:DropDownList ID="EditDept_Manager_Code" runat="server" Width="155px" ValidationGroup="Edit">
                                </asp:DropDownList></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 70px; padding-top: 6px;" valign="top">
                                &nbsp;&nbsp;备注信息：</td>
                            <td colspan="2" valign="top" style="padding-top: 6px;">
                                <asp:TextBox ID="EditRem" runat="server" Height="60px" TextMode="MultiLine" Width="99%"
                                    MaxLength="200" ValidationGroup="Edit"></asp:TextBox></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td  class="tblfooter" colspan="3"
                                align="right">
                                <asp:Button ID="EditSave" runat="server" Text="保 存" Width="90px" OnClick="EditSave_Click"
                                    ValidationGroup="Edit" />
                                <asp:Button ID="EditBack" runat="server" Text="返 回" Width="90px" OnClick="EditBack_Click" /></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
                <asp:Panel ID="CreatePanel" runat="server" Width="100%">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="tablehaveborder">
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px; width: 18%;">
                                &nbsp;&nbsp;部门编号：</td>
                            <td style="width: 50%;">
                                <asp:Label ID="CreateDept_ID" runat="server" Width="100%" class="id"></asp:Label></td>
                            <td style="width: 32%;">
                                &nbsp;&nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门名称：</td>
                            <td>
                                <asp:TextBox ID="CreateDept_Name" runat="server" MaxLength="50" ValidationGroup="Create"></asp:TextBox></td>
                            <td>
                                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="CreateDept_Name"
                                    Display="Dynamic" ErrorMessage="请输入部门名称！" ValidationGroup="Create"></asp:RequiredFieldValidator></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;所属部门：</td>
                            <td>
                                <asp:DropDownList ID="CreateDep_Dept_ID" runat="server" Width="152px" AutoPostBack="True"
                                    OnSelectedIndexChanged="CreateDep_Dept_ID_SelectedIndexChanged">
                                </asp:DropDownList></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;联系电话：</td>
                            <td>
                                <asp:TextBox ID="CreateDept_Tel" runat="server" MaxLength="50" ValidationGroup="Create"></asp:TextBox></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门负责人：</td>
                            <td>
                                <asp:DropDownList ID="CreateDept_Manager_Code" runat="server" Width="155px" ValidationGroup="Create">
                                </asp:DropDownList></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 70px; padding-top: 6px;" valign="top">
                                &nbsp;&nbsp;备注信息：</td>
                            <td colspan="2" valign="top" style="padding-top: 6px;">
                                <asp:TextBox ID="CreateRem" runat="server" Height="60px" TextMode="MultiLine" Width="99%"
                                    MaxLength="200" ValidationGroup="Create"></asp:TextBox></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td  class="tblfooter" colspan="3"
                                align="right">
                                &nbsp;<asp:Button ID="CreateSave" runat="server" Text="保 存" Width="90px" OnClick="CreateSave_Click"
                                    ValidationGroup="Create" />
                                <asp:Button ID="CreateBack" runat="server" Text="返 回" Width="90px" OnClick="CreateBack_Click" /></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
                <asp:Panel ID="DetailPanel" runat="server" Width="100%">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" class="tablehaveborder">
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px; width: 18%;">
                                &nbsp;&nbsp;部门编号：</td>
                            <td style="width: 50%;">
                                <asp:Label ID="DetailDept_ID" runat="server" Width="100%" class="id"></asp:Label></td>
                            <td style="width: 32%;">
                                &nbsp;
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门名称：</td>
                            <td>
                                <asp:Label ID="DetailDept_Name" runat="server" Width="100%"></asp:Label></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;所属部门：</td>
                            <td>
                                <asp:Label ID="DetailDep_Dept_ID" runat="server" Width="100%"></asp:Label></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;联系电话：</td>
                            <td>
                                <asp:Label ID="DetailDept_Tel" runat="server" Width="100%"></asp:Label></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 24px;">
                                &nbsp;&nbsp;部门负责人：</td>
                            <td>
                                <asp:Label ID="DetailDept_Manager" runat="server" Width="100%"></asp:Label></td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td style="height: 70px; padding-top: 6px;" valign="top">
                                &nbsp;&nbsp;备注信息：</td>
                            <td colspan="2" valign="top" style="padding-top: 6px;">
                                <asp:Label ID="DetailRem" Style="padding-top: 6px;" runat="server" Width="100%"></asp:Label></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                        <tr>
                            <td  class="tblfooter" colspan="3">
                                <asp:Button ID="CreateGo" runat="server" Text="创建新部门" Width="90px" OnClick="CreateGo_Click" />
                                <asp:Button ID="EditGo" runat="server" Text="修 改" Width="90px" OnClick="EditGo_Click" />
                                <asp:Button ID="DeleteGo" runat="server" OnClientClick="javascript:return confirm('您确定要删除此条记录吗？');"
                                    Text="删 除" Width="90px" OnClick="DeleteGo_Click" /></td>
                        </tr>
                        <tr>
                            <td style="height: 1px; background-color: #F0F0F0;" colspan="3">
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
